import http from '../utils/request';

const { get, post } = http('admin');
// 登录
export const login = params => post('/api/auth/signin', params);
// 获取短信验证码
export const getMsg = params => post('/api/open/msg/sendLoginCheckMsg', params);
// 登出
export const logout = params => post('/api/auth/signup', params);
// 获取用户自己的消息列表
export const messageList = params => get('/api/message/messageList', params);
// 获取平台发送消息列表
export const messageSendList = params => get('/api/message/querySendList', params);
// 创建消息
export const createMessage = params => post('/api/message/createMessage', params);
// 设置已读
export const setRead = params => post('/api/message/setRead', params);
// 设置本账号全部已读
export const setAllRead = params => post('/api/message/setAllRead', params);

